using System.ComponentModel.DataAnnotations;

namespace AiPlatformAdmin.Api.Models;

public class TokenUsage : ITenantEntity
{
    public int Id { get; set; }

    [Required]
    public int TenantId { get; set; }

    public int UserId { get; set; }
    public User User { get; set; } = null!;

    public int AgentId { get; set; }
    public Agent Agent { get; set; } = null!;

    public int TokenCount { get; set; }

    public DateTime Timestamp { get; set; } = DateTime.UtcNow;

    [Required]
    [MaxLength(100)]
    public string RequestType { get; set; } = string.Empty;

    // Navigation properties
    public Tenant? Tenant { get; set; }
}
